/*
 * @Author       : DeaneChen
 * @Date         : 2021-08-19 11:07:56
 * @LastEditTime : 2021-08-19 13:31:50
 * @LastEditors  : DeaneChen
 * @Description  : 
 * @FilePath     : \master_controller\Hardware\keyled.h
 * HomePage     : https://luheqiu.com
 */
#ifndef __KEYLED_H
#define __KEYLED_H	 
#include "system.h"	  

 
// KEY Part

#define KEY1_PIN 	PBin(8)
#define KEY2_PIN 	PBin(9)

#define KEY1 	1
#define KEY2    2

extern uint8_t mainKey;
extern uint8_t mainKeyBuff;

void Key_Init(void);	//IO初始化
uint8_t Key_Scan(uint8_t);  		//按键扫描函数	
void InterruptKeyUpdate(void);


// LED Part
#define LED(x) PBout((x+9))         // 9 为 LED对应GPIO口的偏移量
   
void LED_Init(void);    //初始化

#endif
